#30 new
Rick DeNatale

Fwd: [RiCal] Monthly recurrence by month day problem

Reported by Rick DeNatale | April 20th, 2010 @ 03:21 PM

This was introduced by the infinite loop fix.

---------- Forwarded message ---------- From: Claudio_A <cacciaresi@gmail.com>
Date: Mon, Apr 19, 2010 at 5:01 PM
Subject: [RiCal] Monthly recurrence by month day problem
To: RiCal <rical_gem@googlegroups.com>

Hello I'm having a problem with the following calendar:

ical_string = %Q(BEGIN:VCALENDAR
PRODID:-//Google Inc//Google Calendar 70.9054//EN
BEGIN:VEVENT
DTSTART:20100419T100000
DTEND:20100419T110000
RRULE:FREQ=MONTHLY;INTERVAL=2;WKST=MO;BYMONTHDAY=20
END:VEVENT
END:VCALENDAR)

event = RiCal.parse_string(ical_string).first.events.first
y event.occurrences(:starting => Time.now, :before => Time.now +

10.months).map(&:start_time)

  • 2010-04-20T10:00:00+00:00
  • 2010-06-01T10:00:00+00:00
  • 2010-08-01T10:00:00+00:00
  • 2010-10-01T10:00:00+00:00
  • 2010-12-01T10:00:00+00:00
  • 2011-02-01T10:00:00+00:00 => nil

The rrule specifies that the recurrence should be on day number 20
every two months, but after the first occurrence (2010-04-20, the
events are created for the first thay of each month insted of being
created for the number of the day that BYMONTHDAY indicates).

Thanks a lot,
Claudio.

-- You received this message because you are subscribed to the Google
Groups "RiCal" group.
To post to this group, send email to rical_gem@googlegroups.com.
To unsubscribe from this group, send email to
rical_gem+unsubscribe@googlegroups.com.
For more options, visit this group at
http://groups.google.com/group/rical_gem?hl=en.

-- Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Github: http://github.com/rubyredrick
Twitter: @RickDeNatale
WWR: http://www.workingwithrails.com/person/9021-rick-denatale
LinkedIn: http://www.linkedin.com/in/rickdenatale

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

A new icalendar data (RFC 2445) gem for Ruby which supports time zones and enumeration of occurrences

Shared Ticket Bins

Tags

Pages